home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 299 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.3 KB  |  40 lines

  1. Path: news.fast.net!news
  2. From: "Chad R. Laity" <wick@pop.fast.net>
  3. Newsgroups: comp.lang.c
  4. Subject: HP UX 10.0 C programming
  5. Date: 4 Jan 1996 04:01:07 GMT
  6. Organization: FASTNET(tm) PA/NJ/DE Internet 
  7. Message-ID: <4cfje3$qk@nn.fast.net>
  8. NNTP-Posting-Host: abe-ppp340.fast.net
  9. Mime-Version: 1.0
  10. Content-Type: text/plain
  11. Content-Transfer-Encoding: 7bit
  12. X-Mailer: Mozilla 1.2 (Windows; U; 16bit)
  13.  
  14. 2 questions: (1) What is a good book for HP UX 10.0 C programming?
  15.              (2) Why do I get an error on this cut down program listed
  16.                  below when I compile it on an HP 9000 K200 with HP UX 10.0
  17.                  and I do not get an error with our Intergraph server?
  18.                  (basically I just want to get the file size of a file but
  19.                   this buf problem is giving me a head ache)
  20. ----------------------- program ---------------------------------
  21.  
  22. #include <stdio.h>
  23. #include <sys/stat.h>
  24.  
  25. main()
  26. {
  27. int i;
  28. int stat(const char *path, struct stat *buf);    
  29.  
  30. i = stat("/usr2/test/testfile", &buf);           /* line 15 */
  31.  
  32. }
  33.  
  34. ------------------------ error -----------------------------------
  35. Compiled using: cc -Aa test.c
  36.  
  37. cc: "test.c", line 15: error 1588: "buf" undefined.
  38. cc: "test.c", line 15: warning 563: Argument #2 is not the correct type.
  39.  
  40.